<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "t_base_school".
 *
 * @property string $id
 * @property string $school_code 学校代码
 * @property string $school_name 学校名称
 * @property string $school_region 所在地区/市
 * @property string $school_address 学校通讯地址
 * @property string $school_info
 * @property int $school_post 学校邮编
 * @property string $school_img
 * @property string $school_website 学校网址
 * @property string $school_organizer_type 举办方：             0 省级政府             1 地市级政府             2 行业             3 企业             4 公民个人             5 其他
 * @property string $school_organizer_name 举办方名称
 * @property string $school_property 性质             0 公办             1 民办             2 公办民助
 * @property string $school_property_category 性质类别：             1 综合大学              2 理工院校             3 农业院校             4 林业院校             5 医药院校             6 师范院校             7 语文院校             8 财经院校             9 政法院校             10 体育院校             11 艺术院校             12 民族院校
 * @property string $school_type 示范/骨干院校:             0 示范院校             1 骨干院校             2 其他
 * @property string $school_build_date 学校建校时间
 * @property string $school_current_name_date 校名启用时间
 * @property string $pinyin 拼音缩写
 * @property string $recommend 近期是否推荐  1推荐 0 不推荐
 * @property string $jingdu 经度
 * @property string $weidu 纬度
 * @property int $del_flag 删除标示
 * @property string $create_by 创建人
 * @property string $create_time 创建时间
 * @property string $update_by 更新人
 * @property string $update_time 更新时间
 * @property string $type 机构类型（学校、培训机构、管理机构）
 * @property string $status 状态
 */
class TBaseSchool extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 't_base_school';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['id', 'school_code', 'school_name', 'school_property_category', 'school_type', 'school_build_date', 'school_current_name_date', 'pinyin', 'recommend'], 'required'],
            [['school_code', 'school_post', 'del_flag'], 'integer'],
            [['school_info'], 'string'],
            [['school_build_date', 'school_current_name_date', 'create_time', 'update_time'], 'safe'],
            [['id', 'create_by', 'update_by'], 'string', 'max' => 36],
            [['school_name', 'school_region', 'school_address', 'school_img', 'school_website', 'school_organizer_type', 'school_organizer_name', 'school_property', 'school_property_category', 'school_type', 'pinyin', 'recommend', 'jingdu', 'weidu'], 'string', 'max' => 255],
            [['type', 'status'], 'string', 'max' => 64],
            [['id'], 'unique'],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'school_code' => 'School Code',
            'school_name' => 'School Name',
            'school_region' => 'School Region',
            'school_address' => 'School Address',
            'school_info' => 'School Info',
            'school_post' => 'School Post',
            'school_img' => 'School Img',
            'school_website' => 'School Website',
            'school_organizer_type' => 'School Organizer Type',
            'school_organizer_name' => 'School Organizer Name',
            'school_property' => 'School Property',
            'school_property_category' => 'School Property Category',
            'school_type' => 'School Type',
            'school_build_date' => 'School Build Date',
            'school_current_name_date' => 'School Current Name Date',
            'pinyin' => 'Pinyin',
            'recommend' => 'Recommend',
            'jingdu' => 'Jingdu',
            'weidu' => 'Weidu',
            'del_flag' => 'Del Flag',
            'create_by' => 'Create By',
            'create_time' => 'Create Time',
            'update_by' => 'Update By',
            'update_time' => 'Update Time',
            'type' => 'Type',
            'status' => 'Status',
        ];
    }
}
